
// ***********************************************************************
// AUTO GENERATED CLASS - Do Not Modify this file, if needed modify .tt
// ***********************************************************************
// Assembly         : InnovaApp_DomainLayer
// Author           : LJO+01
// Created          : 17/11/2013 20:29:50
// ***********************************************************************
// <copyright file="N.A." company="Copyright © Innovacall 2011">
//     Copyright (c) . All rights reserved.
// </copyright>
// <summary>
// Domain layer  
// DomainClass
// </summary>
// ***********************************************************************

using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Collections.Specialized;


namespace InnovaApp.Layers.DomainLayer
{
    /// <summary>
    /// Class InnoProfile
    /// </summary>
    [Serializable]
    public partial class InnoProfile : _DomainLayer_Base  
    {
        #region Primitive Properties
    	
        /// <summary>
        /// Gets or sets Id.
        /// </summary>
        /// <value>The Id.</value>
        /// <remarks>
        /// Foregn key of InnoProfile
        /// 
        /// </remarks>
        public virtual System.Guid Id
        {
            get { return _id; }
            set
            {
                if (_id != value)
                {
                    if (InnoAppUser != null && InnoAppUser.Id != value)
                    {
                        InnoAppUser = null;
                    }
                    _id = value;
                }
            }
        }
        private System.Guid _id;
    	
        /// <summary>
        /// Gets or sets PropertyNames.
        /// </summary>
        /// <value>The PropertyNames.</value>
        public virtual string PropertyNames
        {
            get;
            set;
        }
    	
        /// <summary>
        /// Gets or sets PropertyValuesString.
        /// </summary>
        /// <value>The PropertyValuesString.</value>
        public virtual string PropertyValuesString
        {
            get;
            set;
        }
    	
        /// <summary>
        /// Gets or sets PropertyValuesBinary.
        /// </summary>
        /// <value>The PropertyValuesBinary.</value>
        public virtual byte[] PropertyValuesBinary
        {
            get;
            set;
        }
    	
        /// <summary>
        /// Gets or sets LastUpdatedDate.
        /// </summary>
        /// <value>The LastUpdatedDate.</value>
        public virtual System.DateTime LastUpdatedDate
        {
            get;
            set;
        }
    	
        /// <summary>
        /// Gets or sets rowversion.
        /// </summary>
        /// <value>The rowversion.</value>
        public virtual byte[] rowversion
        {
            get;
            set;
        }

        #endregion

        #region Navigation Properties
        public virtual InnoAppUser InnoAppUser
        {
            get { return _innoAppUser; }
            set
            {
                if (!ReferenceEquals(_innoAppUser, value))
                {
                    var previousValue = _innoAppUser;
                    _innoAppUser = value;
                    FixupInnoAppUser(previousValue);
                }
            }
        }
        private InnoAppUser _innoAppUser;

        #endregion

        #region Association Fixup
    
        private void FixupInnoAppUser(InnoAppUser previousValue)
        {
            if (previousValue != null && ReferenceEquals(previousValue.InnoProfile, this))
            {
                previousValue.InnoProfile = null;
            }
    
            if (InnoAppUser != null)
            {
                InnoAppUser.InnoProfile = this;
                if (Id != InnoAppUser.Id)
                {
                    Id = InnoAppUser.Id;
                }
            }
        }

        #endregion

    }
}
